package cn.itcast.bos.service.base.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.domain.Specification;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import cn.itcast.bos.dao.base.FixedAreaRepository;
import cn.itcast.bos.domain.base.FixedArea;
import cn.itcast.bos.service.base.FixedAreaService;

/**
 * 定区业务接口的实现类
 * 
 * @author 张立
 * @version 1.0 2017-9-8 19:09:09
 */
@Service
@Transactional
public class FixedAreaServiceImpl implements FixedAreaService {

	// 注入dao
	@Autowired
	private FixedAreaRepository fixedAreaRepository;
	@Override
	public void save(FixedArea fixedArea) {
		fixedAreaRepository.save(fixedArea);
	}
	// 分页条件查询
	@Override
	public Page<FixedArea> findPageData(Specification<FixedArea> specification, Pageable pageable) {

		return fixedAreaRepository.findAll(pageable);
	}

}
